package com.laicunba.service.jzh;

import java.math.BigDecimal;
import java.util.List;

import com.laicunba.pojo.FinancingTargetBidDO;
import com.laicunba.pojo.JzhBidOrderDO;
import com.laicunba.service.BaseService;

public interface JzhBidOrderService extends BaseService {
	public class BuyParam {
		private String userId;
		private BigDecimal buyAmt;
		private String financingTargetId;
		private long seq;
		private String cashCouponId;
		private String rateIncrCouponId;
		private boolean isTransferCurrent;
		public boolean isTransferCurrent() {
			return isTransferCurrent;
		}
		public void setTransferCurrent(boolean isTransferCurrent) {
			this.isTransferCurrent = isTransferCurrent;
		}
		public void setCashCouponId(String cashCouponId) {
			this.cashCouponId = cashCouponId;
		}

		public String getCashCouponId() {
			return cashCouponId;
		}

		public void setRateIncrCouponId(String rateIncrCouponId) {
			this.rateIncrCouponId = rateIncrCouponId;
		}

		public String getRateIncrCouponId() {
			return rateIncrCouponId;
		}

		public void setSeq(long seq) {
			this.seq = seq;
		}

		public long getSeq() {
			return seq;
		}

		public String getUserId() {
			return userId;
		}

		public void setUserId(String userId) {
			this.userId = userId;
		}

		public void setBuyAmt(BigDecimal buyAmt) {
			this.buyAmt = buyAmt;
		}

		public BigDecimal getBuyAmt() {
			return buyAmt;
		}

		public String getFinancingTargetId() {
			return financingTargetId;
		}

		public void setFinancingTargetId(String financingTargetId) {
			this.financingTargetId = financingTargetId;
		}

	}

	public class BuyResult {
		private JzhBidOrderDO order;
		private FinancingTargetBidDO bidDO;
		public void setBidDO(FinancingTargetBidDO bidDO) {
			this.bidDO = bidDO;
		}
		public FinancingTargetBidDO getBidDO() {
			return bidDO;
		}

		public void setOrder(JzhBidOrderDO order) {
			this.order = order;
		}

		public JzhBidOrderDO getOrder() {
			return order;
		}

	}

	public BuyResult doPay(BuyParam param);

	public List<String> findNewStatus(String financingTargetId);

	/**
	 * 放款
	 * 
	 * @param bidOrderId
	 * @return
	 */
	public FinancingTargetBidDO makeLoans(String bidOrderId);
}
